Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid duplicate calculation of number of float variables #1067

Merged
merged 4 commits into from
Sep 12, 2023

Conversation

iomaganaris
Copy link
Contributor

@iomaganaris iomaganaris commented Sep 6, 2023

This PR addresses 2 things:

  • Count properly the number of float variables based on codegen_float_variables vector size
  • Refactor the counting of the int variables using STL

@iomaganaris iomaganaris added the bug Something isn't working label Sep 6, 2023
@iomaganaris iomaganaris self-assigned this Sep 6, 2023
Copy link
Member

@alkino alkino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@iomaganaris iomaganaris closed this Sep 6, 2023
@iomaganaris iomaganaris reopened this Sep 6, 2023
@pramodk
Copy link
Contributor

pramodk commented Sep 7, 2023

I would be interested to look at this, especially because CI fails with:

Error: ForNetConTest is a different MOD file than used by NEURON!
Error : NEURON and CoreNEURON must use same mod files for compatibility, 1 different mod file(s) found. Re-compile special and special-core!
Fatal Python error: Aborted

@codecov
Copy link

codecov bot commented Sep 8, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: -0.02% ⚠️

Comparison is base (8af222d) 69.96% compared to head (13d4b1b) 69.94%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1067      +/-   ##
==========================================
- Coverage   69.96%   69.94%   -0.02%     
==========================================
  Files         188      188              
  Lines       25664    25648      -16     
==========================================
- Hits        17956    17940      -16     
  Misses       7708     7708              
Files Changed Coverage Δ
src/codegen/codegen_cpp_visitor.cpp 85.74% <100.00%> (-0.09%) ⬇️

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@iomaganaris iomaganaris changed the title Avoid duplicate calculation of number of float and int variables Avoid duplicate calculation of number of float variables Sep 11, 2023
@iomaganaris
Copy link
Contributor Author

If the CI passes this should now be ready to merge

@1uc
Copy link
Collaborator

1uc commented Sep 11, 2023

You could implement one in terms of the other, then the symmetry between int and float variable remains; but the code duplication is gone.

@bbpbuildbot

This comment has been minimized.

@bbpbuildbot
Copy link
Collaborator

Logfiles from GitLab pipeline #151687 (:white_check_mark:) have been uploaded here!

Status and direct links:

@iomaganaris
Copy link
Contributor Author

@1uc ready to merge? Do you want to give a final look?

@iomaganaris iomaganaris merged commit 0d1ffea into master Sep 12, 2023
16 checks passed
@iomaganaris iomaganaris deleted the magkanar/fix_var_counting branch September 12, 2023 12:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants